#include "ConfigEditor.h"
#include "ConfigSearchBar.h"
#include "ConfigData.h"

#include <QApplication>
#include <QTimer>
#include <QLineEdit>
#include <QSet>
#include <QVector>
#include <QDebug>
#include <QTranslator>



int main(int argc, char *argv[])
{
    QApplication a(argc, argv);

    // registerConfigItemTypes();

    QTranslator translator;
    translator.load(":/translate/config.qm");
    a.installTranslator(&translator);

    Data1 cd;
    cd.setObjectName("data1");
    cd.translatedName = "data1";
    // Data2 cd2;

    ConfigEditor editor(&cd);
    ConfigSearchBarWidget searchBar(&cd);

//    auto w = cd.zoom->createRelatedWidget();
//    w->setAttribute(Qt::WA_DeleteOnClose);

//    cd.zoom->set(6.66);
    editor.resize(editor.minimumSizeHint());
    editor.show();
    searchBar.show();


    return a.exec();
}
